#ifndef __studies_architecture_bussiness__login__h__
#define __studies_architecture_bussiness__login__h__



/** @file */


/** @todo */

// ==> C++ Headers
#include <string>
#include <cctype>
// ==> 3rds Headers

// ==> Our Headers
#include <studies.architecture.returns/codes.h>
        
// ==> Namespaces
using namespace std;

// ==> Macro Constants

// ==> Macro Commands


/** ==> namespace of the organization */
namespace studies {
    /** ==> namespace for the project */
    namespace architecture {
        /** ==> displaying, interacting, transmitting, message, processing,
            object, storing */  
        namespace bussiness {

            // ==> Typedefs 

            // ==> Pre-Declarations

            // ==> Attributes 

            // ==> Functions

            // ==> Classes

            /** 
                @nosubgrouping 
            */
            class login {

                // ==> login - Friends

                /** Class allowed to access private members of @p login, in
                    order to perform tests */
                friend class login_tester;

            public:

                // ==> login - Public Internal Types

                // ==> login - Public Constructors

                /** */
                login(const std::string & p_value) {
                    for (std::string::const_iterator l_ite = p_value.begin();
                         l_ite != p_value.end();
                         ++l_ite) {
                        if (std::isupper(*l_ite)) {
                            throw returns::codes::LOGIN_MALFORMED;
                        }
                        
                    }
                    m_value = p_value;
                }
                
                /** Destructor */
                ~login( ) {}

                // ==> login - Public Accessors

                // ==> login - Public Helpers

                // ==> login - Public Processors

                // ==> login - Public Operators

                /** */
                bool operator==(const login & p_login) const {
                    return (m_value == p_login.m_value);
                }

                /** */
                bool operator!=(const login & p_login) const {
                    return (m_value != p_login.m_value);
                }
                

                // ==> login - Public Attributes


            private:

                // ==> login - Private Internal Types

                // ==> login - Private Constructors

                // ==> login - Private Accessors

                // ==> login - Private Helpers

                // ==> login - Private Processors

                // ==> login - Private Operators

                // ==> login - Private Attributes

                /** */
                std::string m_value;
                
            };
        }
    }
}
// =============================================================================
// I M P L E M E N T A T I O N
// =============================================================================

using namespace studies::architecture::bussiness;


#endif
